import antfu from '@antfu/eslint-config'

export default antfu({
  unocss: true,
  vue: true,
  typescript: true,
  ignores: [
    '**/node_modules',
    '**/dist',
    '**/out',
    '**/dist-electron-builder',
    '**/browsers/**',
    '**/automation-run-snapshots/**',
    '**/logs/**',
    '**/temp-html/**',
    '**/db-backups/**',
    '**/*.log',
    '**/*.log.*',
    '**/*.gz',
    '**/eslint-report.json',
  ],
  rules: {
    // 关闭 console 检查
    'no-console': 'off',
    // 放宽若干严格风格/正则/Node 全局偏好规则以兼容现有代码风格
    'style/max-statements-per-line': 'off',
    'no-sequences': 'off',
    'no-unreachable-loop': 'off',
    'node/prefer-global/buffer': 'off',
    'node/prefer-global/process': 'off',
    'regexp/no-dupe-disjunctions': 'off',
    'regexp/no-unused-capturing-group': 'off',
  },
})
